- Reader <Env, A> (Func<Env, A> runReader)
- Pure (A value)
- Asks (Func<Env, A> f)
- AsksM (Func<Env, Reader<Env, A>> f)
- Lift (Pure<A> monad)
- Lift (Func<A> f)
- With <Env1> (Func<Env1, Env> f)
- Local (Func<Env, Env> f)
- Map <B> (Func<A, B> f)
- Select <B> (Func<A, B> f)
- Bind <B> (Func<A, K<Reader<Env>, B>> f)
- Bind <B> (Func<A, Reader<Env, B>> f)
- Bind <B> (Func<A, Ask<Env, B>> f)
- SelectMany <B, C> (Func<A, K<Reader<Env>, B>> bind, Func<A, B, C> project)
- SelectMany <B, C> (Func<A, Reader<Env, B>> bind, Func<A, B, C> project)
- SelectMany <B, C> (Func<A, Pure<B>> bind, Func<A, B, C> project)
- SelectMany <B, C> (Func<A, Ask<Env, B>> bind, Func<A, B, C> project)
- Run (Env env)
- ReaderExt
- Reader
- bind <Env, A, B> (Reader<Env, A> ma, Func<A, Reader<Env, B>> f)
- map <Env, A, B> (Func<A, B> f, Reader<Env, A> ma)
- Pure <Env, A> (A value)
- apply <Env, A, B> (Reader<Env, Func<A, B>> mf, Reader<Env, A> ma)
- action <Env, A, B> (Reader<Env, A> ma, Reader<Env, B> mb)
- ask <Env> ()
- asks <A, Env> (Func<Env, A> f)
- asksM <Env, A> (Func<Env, Reader<Env, A>> f)
- local <Env, A> (Func<Env, Env> f, Reader<Env, A> ma)
- Reader <Env>
record Reader <Env, A> (Func<Env, A> runReader) Source #
Reader
monad transformer, which adds a static environment to a given monad.
type | Env | Reader environment type |
type | M | Given monad trait |
type | A | Bound value type |
param | runReader | Transducer that represents the transformer operation |
method Reader<Env, A> Pure (A value) Source #
Lift a pure value into the monad-transformer
param | value | Value to lift |
returns |
|
method Reader<Env, A> Asks (Func<Env, A> f) Source #
Extracts the environment value and maps it to the bound value
param | f | Environment mapping function |
returns |
|
method Reader<Env, A> AsksM (Func<Env, Reader<Env, A>> f) Source #
Extracts the environment value and maps it to the bound value
param | f | Environment mapping function |
returns |
|
method Reader<Env, A> Lift (Pure<A> monad) Source #
Lifts a given monad into the transformer
param | monad | Monad to lift |
returns |
|
method Reader<Env, A> Lift (Func<A> f) Source #
Lifts a unit function into the transformer
param | f | Function to lift |
returns |
|
method Reader<Env1, A> With <Env1> (Func<Env1, Env> f) Source #
Maps the Reader's environment value
param | f | Mapping function |
returns |
|
method Reader<Env, A> Local (Func<Env, Env> f) Source #
Maps the Reader's environment value
param | f | Mapping function |
returns |
|
method Reader<Env, B> Map <B> (Func<A, B> f) Source #
Maps the bound value
type | B | Target bound value type |
param | f | Mapping function |
returns |
|
method Reader<Env, B> Select <B> (Func<A, B> f) Source #
Maps the bound value
type | B | Target bound value type |
param | f | Mapping transducer |
returns |
|
method Reader<Env, B> Bind <B> (Func<A, K<Reader<Env>, B>> f) Source #
Monad bind operation
type | B | Target bound value type |
param | f | Mapping function |
returns |
|
method Reader<Env, B> Bind <B> (Func<A, Reader<Env, B>> f) Source #
Monad bind operation
type | B | Target bound value type |
param | f | Mapping function |
returns |
|
method Reader<Env, B> Bind <B> (Func<A, Ask<Env, B>> f) Source #
Monad bind operation
type | B | Target bound value type |
param | f | Mapping function |
returns |
|
method Reader<Env, C> SelectMany <B, C> (Func<A, K<Reader<Env>, B>> bind, Func<A, B, C> project) Source #
Monad bind operation
type | B | Intermediate bound value type |
type | C | Target bound value type |
param | bind | Monadic bind function |
param | project | Projection function |
returns |
|
method Reader<Env, C> SelectMany <B, C> (Func<A, Reader<Env, B>> bind, Func<A, B, C> project) Source #
Monad bind operation
type | B | Intermediate bound value type |
type | C | Target bound value type |
param | bind | Monadic bind function |
param | project | Projection function |
returns |
|
method Reader<Env, C> SelectMany <B, C> (Func<A, Pure<B>> bind, Func<A, B, C> project) Source #
Monad bind operation
type | B | Intermediate bound value type |
type | C | Target bound value type |
param | bind | Monadic bind function |
param | project | Projection function |
returns |
|
method Reader<Env, C> SelectMany <B, C> (Func<A, Ask<Env, B>> bind, Func<A, B, C> project) Source #
Monad bind operation
type | B | Intermediate bound value type |
type | C | Target bound value type |
param | bind | Monadic bind function |
param | project | Projection function |
returns |
|
Reader monad extensions